package com.lorenzogao.latte_core.ext

import android.content.Context
import com.lorenzogao.latte_core.app.Latte

/**
 *  create by LorenzoGao
 *  email: 2508719070@qq.com
 *  TIME: 2020-01-08 16:10
 *  description:
 */


fun Context.getScreenWidth(): Int {
    val resource = this.resources
    val dm = resource.displayMetrics
    return dm.widthPixels
}

fun Context.getScreenHeight(): Int {
    val resource = this.resources
    val dm = resource.displayMetrics
    return dm.heightPixels
}